import {
	http
} from '@/node_modules/uview-plus'

/**
 * @function 用户已绑定的水表-所有
 */
export const userMeterAll = (data) => http.post('/userMeter/all', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 用户已绑定的水表-新增
 */
export const userMeterAdd = (data) => http.post('/userMeter/add', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 获取用户信息
 */
export const userMeterDel = (data) => http.post('/userMeter/del', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 获取用户信息
 */
export const baseInfo = (data) => http.post('/user/baseInfo', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 查询历史订单
 */
export const orderList = (data) => http.post('/order/pageList', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 更新备注
 */
export const userMeterUpdate = (data) => http.post('/userMeter/update', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 创建订单
 */
export const waterMeterRecharge = (data) => http.post('/order/waterMeterRecharge', data, {
	custom: {
		auth: 'user'
	}
});


/**
 * @function 立即支付
 */
export const payUnify = (data) => http.post('/pay/unify', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 修改密码
 */
export const updateLoginSecret = (data) => http.post('/user/updateLoginSecret', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 添加发票抬头
 */
export const addInvoiceTitle = (data) => http.post('/invoice/invoiceTitle/add', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 获取发票抬头
 */
export const getInvoiceTitle = (data) => http.post('/invoice/invoiceTitle/all', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 删除发票抬头
 */
export const delInvoiceTitle = (data) => http.post('/invoice/invoiceTitle/del', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 获取发票抬头详情
 */
export const invoiceTitleInfo = (data) => http.post('/invoice/invoiceTitle/detail', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 更新
 */
export const updateInvoiceTitle = (data) => http.post('/invoice/invoiceTitle/update', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 添加发票
 */
export const addInvoiceApply = (data) => http.post('/invoice/invoiceApply/add', data, {
	custom: {
		auth: 'user'
	}
});

/**
 * @function 添加发票
 */
export const invoiceApplyLog = (data) => http.post('/invoice/invoiceApply/pageList', data, {
	custom: {
		auth: 'user'
	}
});

